﻿///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Apr 16 2008)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////

#include "ImageConverBaseDialog.h"

///////////////////////////////////////////////////////////////////////////

MyDialog2::MyDialog2( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : wxDialog( parent, id, title, pos, size, style )
{
	this->SetSizeHints( wxDefaultSize, wxDefaultSize );
	
	wxBoxSizer* bSizer16;
	bSizer16 = new wxBoxSizer( wxVERTICAL );
	
	wxBoxSizer* bSizer17;
	bSizer17 = new wxBoxSizer( wxHORIZONTAL );
	
	wxGridSizer* gSizer1;
	gSizer1 = new wxGridSizer( 2, 1, 0, 0 );
	
	m_dirPickerSource = new wxDirPickerCtrl( this, wxID_ANY, wxEmptyString, wxT("Select a folder"), wxDefaultPosition, wxDefaultSize, wxDIRP_DEFAULT_STYLE );
	gSizer1->Add( m_dirPickerSource, 0, wxALIGN_CENTER|wxALL|wxEXPAND, 5 );
	
	wxBoxSizer* bSizer22;
	bSizer22 = new wxBoxSizer( wxHORIZONTAL );
	

	m_checkRecursion = new wxCheckBox( this, wxID_ANY, wxT("递归子目录"), wxDefaultPosition, wxDefaultSize, 0 );
	m_checkRecursion->SetValue(true);
	
	bSizer22->Add( m_checkRecursion, 0, wxALIGN_CENTER|wxALL, 5 );
	
	gSizer1->Add( bSizer22, 1, wxEXPAND, 5 );
	
	wxBoxSizer* bSizer21;
	bSizer21 = new wxBoxSizer( wxHORIZONTAL );
	
	scaleText = new wxStaticText( this, wxID_ANY, wxT("缩放:"), wxDefaultPosition, wxDefaultSize, 0 );
	scaleText->Wrap( -1 );
	bSizer21->Add( scaleText, 0, wxALIGN_CENTER|wxALL, 5 );
	
	wxString m_choiceScaleChoices[] = { wxT("0.25"), wxT("0.5"), wxT("1.5"), wxT("2") };
	int m_choiceScaleNChoices = sizeof( m_choiceScaleChoices ) / sizeof( wxString );
	m_choiceScale = new wxChoice( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_choiceScaleNChoices, m_choiceScaleChoices, 0 );
	m_choiceScale->SetSelection( 0 );
	bSizer21->Add( m_choiceScale, 0, wxALIGN_CENTER|wxALL, 10 );
	
	m_staticText3 = new wxStaticText( this, wxID_ANY, wxT("最小过滤:"), wxDefaultPosition, wxDefaultSize, 0 );
	m_staticText3->Wrap( -1 );
	bSizer21->Add( m_staticText3, 0, wxALIGN_CENTER|wxALL, 5 );
	
	wxString m_choiceMinFitChoices[] = { wxT("32"), wxT("64"), wxT("128"), wxT("256"), wxT("1024"), wxT("2048") };
	int m_choiceMinFitNChoices = sizeof( m_choiceMinFitChoices ) / sizeof( wxString );
	m_choiceMinFit = new wxChoice( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_choiceMinFitNChoices, m_choiceMinFitChoices, 0 );
	m_choiceMinFit->SetSelection( 3 );
	m_choiceMinFit->SetMinSize( wxSize( 70,-1 ) );
	
	bSizer21->Add( m_choiceMinFit, 0, wxALL, 5 );
	
	gSizer1->Add( bSizer21, 1, wxEXPAND, 5 );
	
	bSizer17->Add( gSizer1, 1, wxEXPAND, 5 );
	
	wxStaticBoxSizer* sbSizer4;
	sbSizer4 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, wxT("选择需要转变的文件类型") ), wxVERTICAL );
	
	wxGridSizer* gSizer4;
	gSizer4 = new wxGridSizer( 2, 2, 0, 0 );
	
	m_jpgcheckBox = new wxCheckBox( this, wxID_ANY, wxT("jpg"), wxDefaultPosition, wxDefaultSize, 0 );
	m_jpgcheckBox->SetValue(true);
	
	gSizer4->Add( m_jpgcheckBox, 0, wxALL, 5 );
	
	m_tgacheckBox2 = new wxCheckBox( this, wxID_ANY, wxT("tga"), wxDefaultPosition, wxDefaultSize, 0 );
	m_tgacheckBox2->SetValue(true);
	
	gSizer4->Add( m_tgacheckBox2, 0, wxALL, 5 );
	
	m_pengcheckBox = new wxCheckBox( this, wxID_ANY, wxT("png"), wxDefaultPosition, wxDefaultSize, 0 );
	m_pengcheckBox->SetValue(true);
	
	gSizer4->Add( m_pengcheckBox, 0, wxALL, 5 );
	
	m_bmpcheckBox4 = new wxCheckBox( this, wxID_ANY, wxT("bmp"), wxDefaultPosition, wxDefaultSize, 0 );
	m_bmpcheckBox4->SetValue(true);
	
	gSizer4->Add( m_bmpcheckBox4, 0, wxALL, 5 );
	
	sbSizer4->Add( gSizer4, 1, wxALL|wxEXPAND, 5 );
	
	bSizer17->Add( sbSizer4, 1, wxALL|wxEXPAND, 5 );
	
	bSizer16->Add( bSizer17, 1, wxEXPAND, 5 );
	
	wxGridSizer* gSizer3;
	gSizer3 = new wxGridSizer( 1, 1, 0, 0 );
	
	wxStaticBoxSizer* sbSizer3;
	sbSizer3 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, wxT("复制原文件") ), wxHORIZONTAL );
	
	m_radioBtnCpy = new wxCheckBox( this, wxID_ANY, wxT("复制原文件到目标目录    "), wxDefaultPosition, wxDefaultSize, 0 );
	m_radioBtnCpy->SetValue(true);
	
	sbSizer3->Add( m_radioBtnCpy, 0, wxALIGN_CENTER|wxALL, 5 );
	
	m_dirPickerDes = new wxDirPickerCtrl( this, wxID_ANY, wxT("目录文件夹"), wxT("Select a folder"), wxDefaultPosition, wxSize( -1,-1 ), wxDIRP_DEFAULT_STYLE );
	m_dirPickerDes->SetMinSize( wxSize( 400,50 ) );
	
	sbSizer3->Add( m_dirPickerDes, 0, wxALIGN_CENTER, 5 );
	
	gSizer3->Add( sbSizer3, 1, wxALL, 5 );
	
	bSizer16->Add( gSizer3, 1, wxEXPAND, 5 );
	
	wxBoxSizer* bSizer18;
	bSizer18 = new wxBoxSizer( wxHORIZONTAL );
	
	m_buttonConvert = new wxButton( this, wxID_ANY, wxT("开始"), wxDefaultPosition, wxDefaultSize, 0 );
	bSizer18->Add( m_buttonConvert, 0, wxALIGN_CENTER|wxLEFT|wxRIGHT, 20 );
	
	m_gauge1 = new wxGauge( this, wxID_ANY, 100, wxDefaultPosition, wxDefaultSize, wxGA_HORIZONTAL );
	m_gauge1->SetMinSize( wxSize( 300,-1 ) );
	
	bSizer18->Add( m_gauge1, 0, wxALIGN_CENTER|wxLEFT|wxRIGHT, 10 );
	
	m_buttonExit = new wxButton( this, wxID_ANY, wxT("退出"), wxDefaultPosition, wxDefaultSize, 0 );
	bSizer18->Add( m_buttonExit, 0, wxALIGN_CENTER|wxFIXED_MINSIZE|wxLEFT|wxRIGHT, 20 );
	
	bSizer16->Add( bSizer18, 1, wxALIGN_CENTER|wxBOTTOM|wxEXPAND, 50 );
	
	this->SetSizer( bSizer16 );
	this->Layout();
	
	// Connect Events
	m_dirPickerSource->Connect( wxEVT_COMMAND_DIRPICKER_CHANGED, wxFileDirPickerEventHandler( MyDialog2::OnSourceDirChange ), NULL, this );
	m_choiceScale->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( MyDialog2::OnSelectScale ), NULL, this );
	m_choiceMinFit->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( MyDialog2::OnminFitChange ), NULL, this );
	m_jpgcheckBox->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( MyDialog2::OnJpgChecked ), NULL, this );
	m_tgacheckBox2->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( MyDialog2::OntgaChecked ), NULL, this );
	m_pengcheckBox->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( MyDialog2::OnpngChecked ), NULL, this );
	m_bmpcheckBox4->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( MyDialog2::OnbmpChecked ), NULL, this );
	m_dirPickerDes->Connect( wxEVT_COMMAND_DIRPICKER_CHANGED, wxFileDirPickerEventHandler( MyDialog2::OnDesDirChange ), NULL, this );
	m_buttonConvert->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( MyDialog2::OnConvert ), NULL, this );
	m_buttonExit->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( MyDialog2::OnExit ), NULL, this );
}

MyDialog2::~MyDialog2()
{
	// Disconnect Events
	m_dirPickerSource->Disconnect( wxEVT_COMMAND_DIRPICKER_CHANGED, wxFileDirPickerEventHandler( MyDialog2::OnSourceDirChange ), NULL, this );
	m_choiceScale->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( MyDialog2::OnSelectScale ), NULL, this );
	m_choiceMinFit->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( MyDialog2::OnminFitChange ), NULL, this );
	m_jpgcheckBox->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( MyDialog2::OnJpgChecked ), NULL, this );
	m_tgacheckBox2->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( MyDialog2::OntgaChecked ), NULL, this );
	m_pengcheckBox->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( MyDialog2::OnpngChecked ), NULL, this );
	m_bmpcheckBox4->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( MyDialog2::OnbmpChecked ), NULL, this );
	m_dirPickerDes->Disconnect( wxEVT_COMMAND_DIRPICKER_CHANGED, wxFileDirPickerEventHandler( MyDialog2::OnDesDirChange ), NULL, this );
	m_buttonConvert->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( MyDialog2::OnConvert ), NULL, this );
	m_buttonExit->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( MyDialog2::OnExit ), NULL, this );
}
